General Analysis of Suicide Rates
Our aim is to make general analysis of suicide rates and we will
explain these rates in detail.
- Dataset Feature List:
- country
- year
- sex
- age
- suicides_no
- population
- suicides/100k pop
- country-year
- HDI for year
- gdp_for_year
- gdp_per_capita
- generation
d2015 <- read.csv("datasets/2015.csv")
d2016 <- read.csv("datasets/2016.csv")
d2017 <- read.csv("datasets/2017.csv")
d2018 <- read.csv("datasets/2018.csv")
d2019 <- read.csv("datasets/2019.csv")
suicide <- read.csv("datasets/suicide.csv")
Displaying the data
head(d2015)
Data frame is now printed using kable.
| Switzerland |
Western Europe |
1 |
7.587 |
0.03411 |
1.39651 |
1.34951 |
0.94143 |
0.66557 |
0.41978 |
0.29678 |
2.51738 |
| Iceland |
Western Europe |
2 |
7.561 |
0.04884 |
1.30232 |
1.40223 |
0.94784 |
0.62877 |
0.14145 |
0.43630 |
2.70201 |
| Denmark |
Western Europe |
3 |
7.527 |
0.03328 |
1.32548 |
1.36058 |
0.87464 |
0.64938 |
0.48357 |
0.34139 |
2.49204 |
| Norway |
Western Europe |
4 |
7.522 |
0.03880 |
1.45900 |
1.33095 |
0.88521 |
0.66973 |
0.36503 |
0.34699 |
2.46531 |
| Canada |
North America |
5 |
7.427 |
0.03553 |
1.32629 |
1.32261 |
0.90563 |
0.63297 |
0.32957 |
0.45811 |
2.45176 |
| Finland |
Western Europe |
6 |
7.406 |
0.03140 |
1.29025 |
1.31826 |
0.88911 |
0.64169 |
0.41372 |
0.23351 |
2.61955 |
head(d2016)
Data frame is now printed using kable.
| Denmark |
Western Europe |
1 |
7.526 |
7.460 |
7.592 |
1.44178 |
1.16374 |
0.79504 |
0.57941 |
0.44453 |
0.36171 |
2.73939 |
| Switzerland |
Western Europe |
2 |
7.509 |
7.428 |
7.590 |
1.52733 |
1.14524 |
0.86303 |
0.58557 |
0.41203 |
0.28083 |
2.69463 |
| Iceland |
Western Europe |
3 |
7.501 |
7.333 |
7.669 |
1.42666 |
1.18326 |
0.86733 |
0.56624 |
0.14975 |
0.47678 |
2.83137 |
| Norway |
Western Europe |
4 |
7.498 |
7.421 |
7.575 |
1.57744 |
1.12690 |
0.79579 |
0.59609 |
0.35776 |
0.37895 |
2.66465 |
| Finland |
Western Europe |
5 |
7.413 |
7.351 |
7.475 |
1.40598 |
1.13464 |
0.81091 |
0.57104 |
0.41004 |
0.25492 |
2.82596 |
| Canada |
North America |
6 |
7.404 |
7.335 |
7.473 |
1.44015 |
1.09610 |
0.82760 |
0.57370 |
0.31329 |
0.44834 |
2.70485 |
head(d2017)
Data frame is now printed using kable.
| Norway |
1 |
7.537 |
7.594445 |
7.479556 |
1.616463 |
1.533524 |
0.7966665 |
0.6354226 |
0.3620122 |
0.3159638 |
2.277027 |
| Denmark |
2 |
7.522 |
7.581728 |
7.462272 |
1.482383 |
1.551122 |
0.7925655 |
0.6260067 |
0.3552805 |
0.4007701 |
2.313707 |
| Iceland |
3 |
7.504 |
7.622031 |
7.385970 |
1.480633 |
1.610574 |
0.8335521 |
0.6271626 |
0.4755402 |
0.1535266 |
2.322715 |
| Switzerland |
4 |
7.494 |
7.561772 |
7.426228 |
1.564980 |
1.516912 |
0.8581313 |
0.6200706 |
0.2905493 |
0.3670073 |
2.276716 |
| Finland |
5 |
7.469 |
7.527542 |
7.410458 |
1.443572 |
1.540247 |
0.8091577 |
0.6179509 |
0.2454828 |
0.3826115 |
2.430182 |
| Netherlands |
6 |
7.377 |
7.427426 |
7.326574 |
1.503945 |
1.428939 |
0.8106961 |
0.5853845 |
0.4704898 |
0.2826618 |
2.294804 |
head(d2018)
Data frame is now printed using kable.
| 1 |
Finland |
7.632 |
1.305 |
1.592 |
0.874 |
0.681 |
0.202 |
0.393 |
| 2 |
Norway |
7.594 |
1.456 |
1.582 |
0.861 |
0.686 |
0.286 |
0.340 |
| 3 |
Denmark |
7.555 |
1.351 |
1.590 |
0.868 |
0.683 |
0.284 |
0.408 |
| 4 |
Iceland |
7.495 |
1.343 |
1.644 |
0.914 |
0.677 |
0.353 |
0.138 |
| 5 |
Switzerland |
7.487 |
1.420 |
1.549 |
0.927 |
0.660 |
0.256 |
0.357 |
| 6 |
Netherlands |
7.441 |
1.361 |
1.488 |
0.878 |
0.638 |
0.333 |
0.295 |
head(d2019)
Data frame is now printed using kable.
| 1 |
Finland |
7.769 |
1.340 |
1.587 |
0.986 |
0.596 |
0.153 |
0.393 |
| 2 |
Denmark |
7.600 |
1.383 |
1.573 |
0.996 |
0.592 |
0.252 |
0.410 |
| 3 |
Norway |
7.554 |
1.488 |
1.582 |
1.028 |
0.603 |
0.271 |
0.341 |
| 4 |
Iceland |
7.494 |
1.380 |
1.624 |
1.026 |
0.591 |
0.354 |
0.118 |
| 5 |
Netherlands |
7.488 |
1.396 |
1.522 |
0.999 |
0.557 |
0.322 |
0.298 |
| 6 |
Switzerland |
7.480 |
1.452 |
1.526 |
1.052 |
0.572 |
0.263 |
0.343 |
head(suicide)
Data frame is now printed using kable.
| Albania |
1987 |
male |
15-24 years |
21 |
312900 |
6.71 |
Albania1987 |
NA |
2,156,624,900 |
796 |
Generation X |
| Albania |
1987 |
male |
35-54 years |
16 |
308000 |
5.19 |
Albania1987 |
NA |
2,156,624,900 |
796 |
Silent |
| Albania |
1987 |
female |
15-24 years |
14 |
289700 |
4.83 |
Albania1987 |
NA |
2,156,624,900 |
796 |
Generation X |
| Albania |
1987 |
male |
75+ years |
1 |
21800 |
4.59 |
Albania1987 |
NA |
2,156,624,900 |
796 |
G.I. Generation |
| Albania |
1987 |
male |
25-34 years |
9 |
274300 |
3.28 |
Albania1987 |
NA |
2,156,624,900 |
796 |
Boomers |
| Albania |
1987 |
female |
75+ years |
1 |
35600 |
2.81 |
Albania1987 |
NA |
2,156,624,900 |
796 |
G.I. Generation |
First 5 countries First let’s see the top 5 for the
years 2015, 2016. 2017, 2018, and 2019.
d2015[,c("Country", "Happiness.Rank", "Happiness.Score")] |> head(5)
## Country Happiness.Rank Happiness.Score
## 1 Switzerland 1 7.587
## 2 Iceland 2 7.561
## 3 Denmark 3 7.527
## 4 Norway 4 7.522
## 5 Canada 5 7.427
d2016[,c("Country", "Happiness.Rank", "Happiness.Score")] |> head(5)
## Country Happiness.Rank Happiness.Score
## 1 Denmark 1 7.526
## 2 Switzerland 2 7.509
## 3 Iceland 3 7.501
## 4 Norway 4 7.498
## 5 Finland 5 7.413
d2017[,c("Country", "Happiness.Rank", "Happiness.Score")] |> head(5)
## Country Happiness.Rank Happiness.Score
## 1 Norway 1 7.537
## 2 Denmark 2 7.522
## 3 Iceland 3 7.504
## 4 Switzerland 4 7.494
## 5 Finland 5 7.469
d2018[,c("Country.or.region", "Overall.rank", "Score")] |> head(5)
## Country.or.region Overall.rank Score
## 1 Finland 1 7.632
## 2 Norway 2 7.594
## 3 Denmark 3 7.555
## 4 Iceland 4 7.495
## 5 Switzerland 5 7.487
d2019[,c("Country.or.region", "Overall.rank", "Score")] |> head(5)
## Country.or.region Overall.rank Score
## 1 Finland 1 7.769
## 2 Denmark 2 7.600
## 3 Norway 3 7.554
## 4 Iceland 4 7.494
## 5 Netherlands 5 7.488
We can clearly see that the nordic countries like Finland, Norway and
Denkmare are constantly at the top.
Last 5
countries
Now let’s see at the 5 countries that score the
least.
d2015[,c("Country", "Happiness.Rank", "Happiness.Score")] |> tail(5)
## Country Happiness.Rank Happiness.Score
## 154 Rwanda 154 3.465
## 155 Benin 155 3.340
## 156 Syria 156 3.006
## 157 Burundi 157 2.905
## 158 Togo 158 2.839
d2016[,c("Country", "Happiness.Rank", "Happiness.Score")] |> tail(5)
## Country Happiness.Rank Happiness.Score
## 153 Benin 153 3.484
## 154 Afghanistan 154 3.360
## 155 Togo 155 3.303
## 156 Syria 156 3.069
## 157 Burundi 157 2.905
d2017[,c("Country", "Happiness.Rank", "Happiness.Score")] |> tail(5)
## Country Happiness.Rank Happiness.Score
## 151 Rwanda 151 3.471
## 152 Syria 152 3.462
## 153 Tanzania 153 3.349
## 154 Burundi 154 2.905
## 155 Central African Republic 155 2.693
d2018[,c("Country.or.region", "Overall.rank", "Score")] |> tail(5)
## Country.or.region Overall.rank Score
## 152 Yemen 152 3.355
## 153 Tanzania 153 3.303
## 154 South Sudan 154 3.254
## 155 Central African Republic 155 3.083
## 156 Burundi 156 2.905
d2019[,c("Country.or.region", "Overall.rank", "Score")] |> tail(5)
## Country.or.region Overall.rank Score
## 152 Rwanda 152 3.334
## 153 Tanzania 153 3.231
## 154 Afghanistan 154 3.203
## 155 Central African Republic 155 3.083
## 156 South Sudan 156 2.853
library('ggplot2')